package cn.aixuxi.security.service.impl;

import cn.aixuxi.security.entity.SysUser;
import cn.aixuxi.security.mapper.SysUserMapper;
import cn.aixuxi.security.service.SysUserService;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.crypto.password.PasswordEncoder;
import org.springframework.stereotype.Service;

/**
 * 类描述 用户实体类，继承MP通用服务实现类，实现基础增删改查
 *
 * @author ruozhuliufeng
 * @version 1.0
 * @date 2021/4/14 21:35
 */
@Service
public class SysUserServiceImpl extends ServiceImpl<SysUserMapper, SysUser> implements SysUserService {
    @Override
    public SysUser selectByUsername(String username) {
        return getBaseMapper().selectOne(new QueryWrapper<SysUser>().eq("username",username));
    }
}
